Optimal. Leaf size=341 \[ \frac {b d^4 n \log \left (d+\frac {e}{\sqrt {x}}\right ) \left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )}{e^4}-\frac {4 b d^3 n \left (d+\frac {e}{\sqrt {x}}\right ) \left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )}{e^4}+\frac {3 b d^2 n \left (d+\frac {e}{\sqrt {x}}\right )^2 \left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )}{e^4}-\frac {4 b d n \left (d+\frac {e}{\sqrt {x}}\right )^3 \left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )}{3 e^4}+\frac {b n \left (d+\frac {e}{\sqrt {x}}\right )^4 \left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )}{4 e^4}-\frac {\left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )^2}{2 x^2}-\frac {b^2 d^4 n^2 \log ^2\left (d+\frac {e}{\sqrt {x}}\right )}{2 e^4}+\frac {4 b^2 d^3 n^2}{e^3 \sqrt {x}}-\frac {3 b^2 d^2 n^2 \left (d+\frac {e}{\sqrt {x}}\right )^2}{2 e^4}+\frac {4 b^2 d n^2 \left (d+\frac {e}{\sqrt {x}}\right )^3}{9 e^4}-\frac {b^2 n^2 \left (d+\frac {e}{\sqrt {x}}\right )^4}{16 e^4} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.37, antiderivative size = 263, normalized size of antiderivative = 0.77, number of steps used = 8, number of rules used = 8, integrand size = 24, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.333, Rules used = {2454, 2398, 2411, 43, 2334, 12, 14, 2301} \[ -\frac {1}{12} b n \left (\frac {48 d^3 \left (d+\frac {e}{\sqrt {x}}\right )}{e^4}-\frac {36 d^2 \left (d+\frac {e}{\sqrt {x}}\right )^2}{e^4}-\frac {12 d^4 \log \left (d+\frac {e}{\sqrt {x}}\right )}{e^4}+\frac {16 d \left (d+\frac {e}{\sqrt {x}}\right )^3}{e^4}-\frac {3 \left (d+\frac {e}{\sqrt {x}}\right )^4}{e^4}\right ) \left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )-\frac {\left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )^2}{2 x^2}+\frac {4 b^2 d^3 n^2}{e^3 \sqrt {x}}-\frac {3 b^2 d^2 n^2 \left (d+\frac {e}{\sqrt {x}}\right )^2}{2 e^4}-\frac {b^2 d^4 n^2 \log ^2\left (d+\frac {e}{\sqrt {x}}\right )}{2 e^4}+\frac {4 b^2 d n^2 \left (d+\frac {e}{\sqrt {x}}\right )^3}{9 e^4}-\frac {b^2 n^2 \left (d+\frac {e}{\sqrt {x}}\right )^4}{16 e^4} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 12
Rule 14
Rule 43
Rule 2301
Rule 2334
Rule 2398
Rule 2411
Rule 2454
Rubi steps
\begin {align*} \int \frac {\left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )^2}{x^3} \, dx &=-\left (2 \operatorname {Subst}\left (\int x^3 \left (a+b \log \left (c (d+e x)^n\right )\right )^2 \, dx,x,\frac {1}{\sqrt {x}}\right )\right )\\ &=-\frac {\left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )^2}{2 x^2}+(b e n) \operatorname {Subst}\left (\int \frac {x^4 \left (a+b \log \left (c (d+e x)^n\right )\right )}{d+e x} \, dx,x,\frac {1}{\sqrt {x}}\right )\\ &=-\frac {\left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )^2}{2 x^2}+(b n) \operatorname {Subst}\left (\int \frac {\left (-\frac {d}{e}+\frac {x}{e}\right )^4 \left (a+b \log \left (c x^n\right )\right )}{x} \, dx,x,d+\frac {e}{\sqrt {x}}\right )\\ &=-\frac {1}{12} b n \left (\frac {48 d^3 \left (d+\frac {e}{\sqrt {x}}\right )}{e^4}-\frac {36 d^2 \left (d+\frac {e}{\sqrt {x}}\right )^2}{e^4}+\frac {16 d \left (d+\frac {e}{\sqrt {x}}\right )^3}{e^4}-\frac {3 \left (d+\frac {e}{\sqrt {x}}\right )^4}{e^4}-\frac {12 d^4 \log \left (d+\frac {e}{\sqrt {x}}\right )}{e^4}\right ) \left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )-\frac {\left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )^2}{2 x^2}-\left (b^2 n^2\right ) \operatorname {Subst}\left (\int \frac {x \left (-48 d^3+36 d^2 x-16 d x^2+3 x^3\right )+12 d^4 \log (x)}{12 e^4 x} \, dx,x,d+\frac {e}{\sqrt {x}}\right )\\ &=-\frac {1}{12} b n \left (\frac {48 d^3 \left (d+\frac {e}{\sqrt {x}}\right )}{e^4}-\frac {36 d^2 \left (d+\frac {e}{\sqrt {x}}\right )^2}{e^4}+\frac {16 d \left (d+\frac {e}{\sqrt {x}}\right )^3}{e^4}-\frac {3 \left (d+\frac {e}{\sqrt {x}}\right )^4}{e^4}-\frac {12 d^4 \log \left (d+\frac {e}{\sqrt {x}}\right )}{e^4}\right ) \left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )-\frac {\left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )^2}{2 x^2}-\frac {\left (b^2 n^2\right ) \operatorname {Subst}\left (\int \frac {x \left (-48 d^3+36 d^2 x-16 d x^2+3 x^3\right )+12 d^4 \log (x)}{x} \, dx,x,d+\frac {e}{\sqrt {x}}\right )}{12 e^4}\\ &=-\frac {1}{12} b n \left (\frac {48 d^3 \left (d+\frac {e}{\sqrt {x}}\right )}{e^4}-\frac {36 d^2 \left (d+\frac {e}{\sqrt {x}}\right )^2}{e^4}+\frac {16 d \left (d+\frac {e}{\sqrt {x}}\right )^3}{e^4}-\frac {3 \left (d+\frac {e}{\sqrt {x}}\right )^4}{e^4}-\frac {12 d^4 \log \left (d+\frac {e}{\sqrt {x}}\right )}{e^4}\right ) \left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )-\frac {\left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )^2}{2 x^2}-\frac {\left (b^2 n^2\right ) \operatorname {Subst}\left (\int \left (-48 d^3+36 d^2 x-16 d x^2+3 x^3+\frac {12 d^4 \log (x)}{x}\right ) \, dx,x,d+\frac {e}{\sqrt {x}}\right )}{12 e^4}\\ &=-\frac {3 b^2 d^2 n^2 \left (d+\frac {e}{\sqrt {x}}\right )^2}{2 e^4}+\frac {4 b^2 d n^2 \left (d+\frac {e}{\sqrt {x}}\right )^3}{9 e^4}-\frac {b^2 n^2 \left (d+\frac {e}{\sqrt {x}}\right )^4}{16 e^4}+\frac {4 b^2 d^3 n^2}{e^3 \sqrt {x}}-\frac {1}{12} b n \left (\frac {48 d^3 \left (d+\frac {e}{\sqrt {x}}\right )}{e^4}-\frac {36 d^2 \left (d+\frac {e}{\sqrt {x}}\right )^2}{e^4}+\frac {16 d \left (d+\frac {e}{\sqrt {x}}\right )^3}{e^4}-\frac {3 \left (d+\frac {e}{\sqrt {x}}\right )^4}{e^4}-\frac {12 d^4 \log \left (d+\frac {e}{\sqrt {x}}\right )}{e^4}\right ) \left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )-\frac {\left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )^2}{2 x^2}-\frac {\left (b^2 d^4 n^2\right ) \operatorname {Subst}\left (\int \frac {\log (x)}{x} \, dx,x,d+\frac {e}{\sqrt {x}}\right )}{e^4}\\ &=-\frac {3 b^2 d^2 n^2 \left (d+\frac {e}{\sqrt {x}}\right )^2}{2 e^4}+\frac {4 b^2 d n^2 \left (d+\frac {e}{\sqrt {x}}\right )^3}{9 e^4}-\frac {b^2 n^2 \left (d+\frac {e}{\sqrt {x}}\right )^4}{16 e^4}+\frac {4 b^2 d^3 n^2}{e^3 \sqrt {x}}-\frac {b^2 d^4 n^2 \log ^2\left (d+\frac {e}{\sqrt {x}}\right )}{2 e^4}-\frac {1}{12} b n \left (\frac {48 d^3 \left (d+\frac {e}{\sqrt {x}}\right )}{e^4}-\frac {36 d^2 \left (d+\frac {e}{\sqrt {x}}\right )^2}{e^4}+\frac {16 d \left (d+\frac {e}{\sqrt {x}}\right )^3}{e^4}-\frac {3 \left (d+\frac {e}{\sqrt {x}}\right )^4}{e^4}-\frac {12 d^4 \log \left (d+\frac {e}{\sqrt {x}}\right )}{e^4}\right ) \left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )-\frac {\left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )^2}{2 x^2}\\ \end {align*}
________________________________________________________________________________________
Mathematica [C] time = 0.39, size = 473, normalized size = 1.39 \[ -\frac {b n \left (-144 a d^4 x^2 \log \left (d \sqrt {x}+e\right )-144 a d^4 x^2 \log \left (-\frac {e}{d \sqrt {x}}\right )+144 a d^3 e x^{3/2}-72 a d^2 e^2 x+48 a d e^3 \sqrt {x}-36 a e^4+144 b d^4 x^2 \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )-144 b d^4 x^2 \log \left (d \sqrt {x}+e\right ) \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )-144 b d^4 x^2 \log \left (-\frac {e}{d \sqrt {x}}\right ) \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )+144 b d^3 e x^{3/2} \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )-72 b d^2 e^2 x \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )-36 b e^4 \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )+48 b d e^3 \sqrt {x} \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )-144 b d^4 n x^2 \text {Li}_2\left (\frac {e}{d \sqrt {x}}+1\right )-144 b d^4 n x^2 \text {Li}_2\left (\frac {\sqrt {x} d}{e}+1\right )+72 b d^4 n x^2 \log ^2\left (d \sqrt {x}+e\right )+156 b d^4 n x^2 \log \left (d+\frac {e}{\sqrt {x}}\right )-144 b d^4 n x^2 \log \left (d \sqrt {x}+e\right ) \log \left (-\frac {d \sqrt {x}}{e}\right )-300 b d^3 e n x^{3/2}+78 b d^2 e^2 n x-28 b d e^3 n \sqrt {x}+9 b e^4 n\right )+72 e^4 \left (a+b \log \left (c \left (d+\frac {e}{\sqrt {x}}\right )^n\right )\right )^2}{144 e^4 x^2} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.44, size = 361, normalized size = 1.06 \[ -\frac {9 \, b^{2} e^{4} n^{2} + 72 \, b^{2} e^{4} \log \relax (c)^{2} - 36 \, a b e^{4} n + 72 \, a^{2} e^{4} - 72 \, {\left (b^{2} d^{4} n^{2} x^{2} - b^{2} e^{4} n^{2}\right )} \log \left (\frac {d x + e \sqrt {x}}{x}\right )^{2} + 6 \, {\left (13 \, b^{2} d^{2} e^{2} n^{2} - 12 \, a b d^{2} e^{2} n\right )} x - 36 \, {\left (2 \, b^{2} d^{2} e^{2} n x + b^{2} e^{4} n - 4 \, a b e^{4}\right )} \log \relax (c) - 12 \, {\left (6 \, b^{2} d^{2} e^{2} n^{2} x + 3 \, b^{2} e^{4} n^{2} - 12 \, a b e^{4} n - {\left (25 \, b^{2} d^{4} n^{2} - 12 \, a b d^{4} n\right )} x^{2} + 12 \, {\left (b^{2} d^{4} n x^{2} - b^{2} e^{4} n\right )} \log \relax (c) - 4 \, {\left (3 \, b^{2} d^{3} e n^{2} x + b^{2} d e^{3} n^{2}\right )} \sqrt {x}\right )} \log \left (\frac {d x + e \sqrt {x}}{x}\right ) - 4 \, {\left (7 \, b^{2} d e^{3} n^{2} - 12 \, a b d e^{3} n + 3 \, {\left (25 \, b^{2} d^{3} e n^{2} - 12 \, a b d^{3} e n\right )} x - 12 \, {\left (3 \, b^{2} d^{3} e n x + b^{2} d e^{3} n\right )} \log \relax (c)\right )} \sqrt {x}}{144 \, e^{4} x^{2}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [B] time = 0.44, size = 1071, normalized size = 3.14 \[ \text {result too large to display} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [F] time = 0.14, size = 0, normalized size = 0.00 \[ \int \frac {\left (b \ln \left (c \left (d +\frac {e}{\sqrt {x}}\right )^{n}\right )+a \right )^{2}}{x^{3}}\, dx \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.88, size = 321, normalized size = 0.94 \[ \frac {1}{12} \, a b e n {\left (\frac {12 \, d^{4} \log \left (d \sqrt {x} + e\right )}{e^{5}} - \frac {6 \, d^{4} \log \relax (x)}{e^{5}} - \frac {12 \, d^{3} x^{\frac {3}{2}} - 6 \, d^{2} e x + 4 \, d e^{2} \sqrt {x} - 3 \, e^{3}}{e^{4} x^{2}}\right )} + \frac {1}{144} \, {\left (12 \, e n {\left (\frac {12 \, d^{4} \log \left (d \sqrt {x} + e\right )}{e^{5}} - \frac {6 \, d^{4} \log \relax (x)}{e^{5}} - \frac {12 \, d^{3} x^{\frac {3}{2}} - 6 \, d^{2} e x + 4 \, d e^{2} \sqrt {x} - 3 \, e^{3}}{e^{4} x^{2}}\right )} \log \left (c {\left (d + \frac {e}{\sqrt {x}}\right )}^{n}\right ) - \frac {{\left (72 \, d^{4} x^{2} \log \left (d \sqrt {x} + e\right )^{2} + 18 \, d^{4} x^{2} \log \relax (x)^{2} - 150 \, d^{4} x^{2} \log \relax (x) - 300 \, d^{3} e x^{\frac {3}{2}} + 78 \, d^{2} e^{2} x - 28 \, d e^{3} \sqrt {x} + 9 \, e^{4} - 12 \, {\left (6 \, d^{4} x^{2} \log \relax (x) - 25 \, d^{4} x^{2}\right )} \log \left (d \sqrt {x} + e\right )\right )} n^{2}}{e^{4} x^{2}}\right )} b^{2} - \frac {b^{2} \log \left (c {\left (d + \frac {e}{\sqrt {x}}\right )}^{n}\right )^{2}}{2 \, x^{2}} - \frac {a b \log \left (c {\left (d + \frac {e}{\sqrt {x}}\right )}^{n}\right )}{x^{2}} - \frac {a^{2}}{2 \, x^{2}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 0.56, size = 424, normalized size = 1.24 \[ \ln \left (c\,{\left (d+\frac {e}{\sqrt {x}}\right )}^n\right )\,\left (\frac {\frac {b\,d\,\left (4\,a-b\,n\right )}{3\,e}-\frac {4\,a\,b\,d}{3\,e}}{x^{3/2}}-\frac {b\,\left (4\,a-b\,n\right )}{4\,x^2}-\frac {d\,\left (\frac {b\,d\,\left (4\,a-b\,n\right )}{e}-\frac {4\,a\,b\,d}{e}\right )}{2\,e\,x}+\frac {d^2\,\left (\frac {b\,d\,\left (4\,a-b\,n\right )}{e}-\frac {4\,a\,b\,d}{e}\right )}{e^2\,\sqrt {x}}\right )+\frac {\frac {d\,\left (2\,a^2-a\,b\,n+\frac {b^2\,n^2}{4}\right )}{3\,e}-\frac {d\,\left (6\,a^2-b^2\,n^2\right )}{9\,e}}{x^{3/2}}-{\ln \left (c\,{\left (d+\frac {e}{\sqrt {x}}\right )}^n\right )}^2\,\left (\frac {b^2}{2\,x^2}-\frac {b^2\,d^4}{2\,e^4}\right )-\frac {\frac {a^2}{2}-\frac {a\,b\,n}{4}+\frac {b^2\,n^2}{16}}{x^2}-\frac {\frac {d\,\left (\frac {d\,\left (2\,a^2-a\,b\,n+\frac {b^2\,n^2}{4}\right )}{e}-\frac {d\,\left (6\,a^2-b^2\,n^2\right )}{3\,e}\right )}{2\,e}+\frac {b^2\,d^2\,n^2}{4\,e^2}}{x}+\frac {\frac {d\,\left (\frac {d\,\left (\frac {d\,\left (2\,a^2-a\,b\,n+\frac {b^2\,n^2}{4}\right )}{e}-\frac {d\,\left (6\,a^2-b^2\,n^2\right )}{3\,e}\right )}{e}+\frac {b^2\,d^2\,n^2}{2\,e^2}\right )}{e}+\frac {b^2\,d^3\,n^2}{e^3}}{\sqrt {x}}-\frac {\ln \left (d+\frac {e}{\sqrt {x}}\right )\,\left (25\,b^2\,d^4\,n^2-12\,a\,b\,d^4\,n\right )}{12\,e^4} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F(-1)] time = 0.00, size = 0, normalized size = 0.00 \[ \text {Timed out} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________